package com.aptemo.webetek.shared;

import java.io.Serializable;
import java.util.Date;

import com.aptemo.webetek.client.commands.Response;
import com.aptemo.webetek.client.enums.EnumPickStatus;

public class PickBean implements Response, Serializable
{

	/**
	 * 
	 */
	private static final long	serialVersionUID	= -7432385301351172380L;

	private String				id;

	private String				title;

	// private EventBean event;

	private double				odds;

	private EnumPickStatus		status;

	private int					pickedCnt			= 0;

	private String				eventId;
	private String				eventTitle;
	private String				eventDescription;
	private Date				eventDate;
	private String				eventResultDescription;
	private PickBean			eventWinPick;

	protected PickBean()
	{
	}

	public PickBean(String title)
	{
		setTitle(title);
	}

	public void setTitle(String title)
	{
		this.title = title;
	}

	public String getTitle()
	{
		return title;
	}

	public void setId(String id)
	{
		this.id = id;
	}

	public String getId()
	{
		return id;
	}

	public void setEvent(EventBean bet)
	{
		this.eventTitle = bet.getTitle();
		this.eventDescription = bet.getDescription();
		this.eventId = bet.getKey();
		this.eventDate = bet.getDate();
		this.eventResultDescription = bet.getResultDescription();
		this.eventWinPick = bet.getWinPick();
	}

	// public EventBean getBet()
	// {
	// return event;
	// }

	public void setOdds(double odds)
	{
		this.odds = odds;
	}

	public double getOdds()
	{
		// if NaN return 1
		// if (Double.isNaN(odds))
		// {
		// return 1.0;
		// }
		return odds;
	}

	public EnumPickStatus getStatus()
	{
		return status;
	}

	public void setStatus(EnumPickStatus status)
	{
		this.status = status;
	}

	public int getPickedCnt()
	{
		return pickedCnt;

	}

	public void setPickedCnt(int pickedCnt)
	{
		this.pickedCnt = pickedCnt;
	}

	public String getEventKey()
	{
		return eventId;
	}

	public String getEventTitle()
	{
		return eventTitle;
	}

	public String getEventDescription()
	{
		return eventDescription;
	}

	public Date getEventDate()
	{
		return eventDate;
	}

	public String getEventResultDescription()
	{
		return eventResultDescription;
	}

	public PickBean getEventWinPick()
	{
		return eventWinPick;
	}

}
